package com.red.star.macalline.data.entity;

import lombok.Data;
import org.springframework.data.annotation.Id;
import org.springframework.data.mongodb.core.mapping.Document;
import org.springframework.data.mongodb.core.mapping.Field;

import java.util.Date;
import java.util.List;

/**
 * @author nofish.yan@gmail.com
 * @date 2018/2/5.
 * 聊天列表实体
 */
@Data
@Document(collection = "chat_list")
public class ChatList {

    @Id
    private String id;

    /** 当前粉丝ID 　**/
    @Field(value = "fans_id")
    private Integer fansId;

    /** 与当前fans的聊天用户，包括聊天群组 **/
    @Field(value = "chat_users")
    private List<ChatUser> chatUsers;

    @Field(value = "create_time")
    private Date createTime;

    @Field(value = "update_time")
    private Date updateTime;

}
